<?php
class Views_Helpers_ShowNewEvents extends Zend_View_Helper_Abstract{
        public $view;
        public function setView(Zend_View_Interface $view){
            $this->view = $view;
        }

	public function showNewEvents(){
            $jquery = $this->view->jQuery();
            $jquery->enable();
            $jqHandler = ZendX_JQuery_View_Helper_JQuery::getJQueryHandler();
            $way = $this->view->url(array('controller' => 'html', 'action' => 'img'), 'default', true);

            $attrs = array('src'=>'/javascript/backgroundPosition.js');
            $type = 'text/javascript';
            $script = "";
            $this->view->headScript()->appendScript($script, $type, $attrs);

            $function = ' ' . file_get_contents(dirname(__FILE__) . '/ShowNewEvent.js');
            if($jqHandler == '$') $jqHandler = '';
            $jquery->addOnload($jqHandler . $function);
            
            $html = '
                <div class="creammagshowNewLeft">
                    <ul>
                        <li style="margin-left:-10px;"><span class="left_local_pica"></span><a href="#" class="localnavigationmain center_local_pica">активность</a><span class="right_local_pica"></span></li>
                        <li class="clear"></li>
                        <li ><a href="#" class="localnavigationmain">последние 50</a></li>
                        <li ><a href="#" class="localnavigationmain">последние 100</a></li>
                    </ul>
                    <div class="creammagdots" style="height: 20px;"></div>
                    <ul>
                        <li><a href="#" class="localnavigation">от друзей</a></li>
                        <li><span class="left_bird_pica"></span><a href="#" class="localnavigation">фото</a></li>
                        <li><span class="left_bird_pica"></span><a href="#" class="localnavigation">видео</a></li>
                        <li><span class="left_bird_pica"></span><a href="#" class="localnavigation">посты</a></li>
                        <li><a href="#" class="localnavigation">афиша</a></li>
                     </ul>
                </div>
                <div class="creammagshowNewCenter">
                    <div class="creammagdots" style="height: 20px;"></div>
                    <div style="position:relative; display:block; width:70px; height:70px;">
                        <div style="position:relative; display:block; width:70px; height:45px;">
                            <img src="/img/creamgolos_gr.png" id="e1" class="creamgolos_no true" alt="" style="position:relative; margin:1px; display:block; float:left; cursor:pointer;"/>
                            <img src="/img/creamgolos_red.png" id="e2" class="creamgolos_yes false" alt="" style="position:relative; margin:1 px; display:block; float:left;  cursor:pointer;"/>
                            <div class="clear"></div>
                        </div>
                        <p class="creamgolostext creammagMainText" style="text-align:center; font-size:18px; color:#555;">нет</p>
                    </div>
                    <div class="clear"></div>
                    <div class="creammagCarmaall">
                        <div class="creammagCarma1" id="creammagCarmaid3" alt="0">
                            <img src="/img/bcream.png" alt="" />
                        </div>
                        <div class="clear" style="height:10px;"></div>
                        <p style="float:left; width:25px; cursor:pointer;" class="pyes">да</p>
                        <p style="float:left; width:25px; cursor:pointer;" class="pno">нет</p>
                    </div>
                    <div class="clear"></div>
                </div>
                <div class="creammagshowNewRight">
                    <div class="creamLeftTopShortNewsLine"></div>
                    <div class="creamCenterTopShortNewsLine"></div>
                    <div class="creamRightTopShortNewsLine"></div>

                    <div class="clear creamCenterContentShortNewsLine">
                    <h2 class="creammagh2">короткая афиша:</h2>
                    <div class="creammagdotswhite" style="height: 20px;"></div>
                        <div>
                            <h2 class="plikelogo creamRed">МАРТ</h2>
                            <div>
                                <p class="creammagDateAfishaShort creamRed">25 -</p>
                                <p class="creammagContentAfishaShort">
                                <a href="#" class="localauthorshort">IGORA SUN PIPE</a><br/>
                                Курорт Игора
                                Санкт-Петербург
                                </p>
                            </div>
                            <div class="clear"></div>
                            <div>
                                <p class="creammagDateAfishaShort creamRed">21 -</p>
                                <p class="creammagContentAfishaShort">
                                <a href="#" class="localauthorshort">IGORA SUN PIPE</a><br/>
                                Курорт Игора
                                Санкт-Петербург
                                </p>
                            </div>
                            <div class="clear"></div>
                        </div>
                        <div class="creammagdotswhite" style="height: 20px;"></div>
                        <div>
                            <h2 class="plikelogo">АПРЕЛЬ</h2>
                            <div>
                                <p class="creammagDateAfishaShort">25 -</p>
                                <p class="creammagContentAfishaShort">
                                <a href="#" class="localauthorshort">IGORA SUN PIPE</a><br/>
                                Курорт Игора
                                Санкт-Петербург
                                </p>
                            </div>
                            <div class="clear"></div>
                            <div>
                                <p class="creammagDateAfishaShort">21 -</p>
                                <p class="creammagContentAfishaShort">
                                <a href="#" class="localauthorshort">SIMPLE SESSION</a><br/>
                                Таллинн
                                Эстония
                                </p>
                            </div>
                            <div class="clear"></div>
                        </div>
                    </div>
                    
                    <div class="creamLeftBottomShortNewsLine"></div>
                    <div class="creamCenterBottomShortNewsLine"></div>
                    <div class="creamRightBottomShortNewsLine"></div>
                    
                    <div class="clear"></div>
                </div>
                <div class="clear"></div>
                ';
            return $html;
	}
}